package com.suning.sawp.constants;

/**
 * 
 * 缓存常量<br>
 * 〈功能详细描述〉
 *
 * @author 13071470
 * @see [相关类/方法]（可选）
 * @since [产品/模块版本] （可选）
 */
public class CacheKeyConstants {

	private CacheKeyConstants() {
	}

	/**
	 * 默认失效时间 24小时
	 */
	public static final int COMMON_EXPIRE_TIME = 60 * 60 * 24;

	/**
	 * 每天请求充值次数
	 */
	public static final String CHARGE_REQ_TIMES = "SAWP.CHARGE_REQ_TIMES";

	/**
	 * 每天成功充值充值次数
	 */
	public static final String CHARGE_TIMES_DAY = "SAWP.CHARGE_TIMES_DAY";

	/**
	 * POS每天发送短信次数
	 */
	public static final String POS_SENDSMS_TIMES_DAY = "SAWP.POS_SENDSMS_TIMES_DAY";

	/**
	 * 城市编码缓存key
	 */
	public static final String COMMERCE_CITY_CODE_TO_MDM_CODE = "SAWP.CITY_CODE_COMM_TO_MDM";

	/**
	 * 城市编码缓存key2
	 */
	public static final String POS_CITY_CODE_TO_MDM_CODE = "SAWP.POS_CODE_COMM_TO_MDM";

	/**
	 * 城市编码缓存失效时间 7天
	 */
	public static final int CITY_EXPIRE_TIME = 7 * 60 * 60 * 24;

	/**
	 * 门店信息 缓存
	 */
	public static final String STORE_INFO = "SAWP.STORE_INFO";
	/**
	 * 大区下的店铺缓存
	 */
	public static final String REGION_STORE_INFOS = "SAWP.REGION_STORE_INFOS_%s";

	public static final int REGION_STORE_INFOS_EXPIRE_TIME = 3 * 60 * 60 * 24;

	/**
	 * 每天验证异业券失败次数
	 */
	public static final String VALID_HORIZCOUPON_FAIL_TIMES = "SAWP.VALID_HORIZCOUPON_FAIL_TIMES";

	/**
	 * 所有大区缓存
	 */
	public static final String REGION_ALL = "SAWP.REGION_ALL";

	/**
	 * 大区下分公司缓存
	 */
	public static final String BRANCH_BY_REGION = "SAWP.BRANCH_BY_REGION";
	/**
	 * 分公司下缓存
	 */
	public static final String STORE_BY_BRANCH = "SAWP.STORE_BY_BRANCH";
	/**
	 * 门店层级树
	 */
	public static final String STORE_TREE = "SAWP.STORE_TREE";
	/**
	 * 门店层级树
	 */
	public static final String ALL_CATE_BRAND = "SAWP.ALL_CATE_BRAND";

	public static final int REGION_ALL_EXPIRE_TIME = 3 * 60 * 60 * 24;

	/**
	 * 每天请求校验活动次数
	 */
	public static final String VALID_ACT_FAIL_TIMES = "SAWP.VALID_ACT_FAIL_TIMES";

	/**
	 * 服务号对应的云导购Id列表
	 */

	public static final String CLOUD_GUIDE_IDS = "SAWP.CLOUD_GUIDE_IDS";

	/**
	 * 门店预充值活动
	 */
	public static final String PRECHARGE_ACT = "SAWP.PRECHARGE_ACT";

	/**
	 * 券未过期的门店预充值活动
	 */
	public static final String UNEXPIRE_ACT_LIST = "SAWP.UNEXPIRE_ACT_LIST";

	/**
	 * 门店预充值活动缓存时间 1天
	 */
	public static final int PRECHARGE_ACT_EXPIRE = 60 * 60 * 24;

	/**
	 * oms 订单提成，缓存一天
	 */
	public static final String OMS_ORDER_COMMISSION = "SAWP.OMS_ORDER_COMMISSION_%s";

	/**
	 * 退货排行缓存KEY
	 */
	public static final String STORE_RET_GDS_RANK_LIST = "com.suning.sawp.storeman.storeRetGdsRateRankList:";

	/**
	 * 退货排行缓存时间
	 */
	public static final int STORE_RET_GDS_RANK_LIST_EXPIRE_TIME = 1 * 60 * 60;

	/**
	 * 退货统计图表排行缓存KEY
	 */
	public static final String STORE_RET_GDS_CHART_LIST = "SAWP.STORE_RET_GDS_CHART_LIST";

	/**
	 * 退货统计图表缓存时间
	 */
	public static final int STORE_RET_GDS_CHART_EXPIRE_TIME = 1 * 60 * 60;

	/**
	 * 退货统计图表缓存时间
	 */
	public static final int MODEL_MONITOR_EXPIRE_TIME = 2 * 60 * 60;

	/**
	 * 退货统计图表排行缓存KEY
	 */
	public static final String STORE_RET_GDS_HOME = "SAWP.STORE_RET_GDS_HOME_%s_%s_%s";
	/**
	 * 退货统计首页缓存时间-1小时
	 */
	public static final int STORE_RET_GDS_HOME_EXPIRE_TIME = 1 * 60 * 60;

	/**
	 * 样机管理-商品中心-商品基本信息
	 */
	public static final String MODEL_COMM_BASE_INFO = "SAWP.MODEL_COMM_BASE_INFO_%s";
	/**
	 * 样机管理-商品中心-商品簇id
	 */
	public static final String MODEL_COMM_CLUSTER_ID = "SAWP.MODEL_COMM_CLUSTER_ID_%s";
	/**
	 * 样机管理-商品中心-商品簇商品编码列表
	 */
	public static final String MODEL_COMM_CODE_CLUSTER_LIST = "SAWP.MODEL_COMM_CODE_CLUSTER_LIST_%s";
	/**
	 * 样机管理-商品中心-缓存时间-12小时
	 */
	public static final int MODEL_COMM_EXPIRE_TIME = 60 * 60 * 12;
	/**
	 * 样机管理-后台管理-excel导出-记录当前导出的任务数量
	 */
	public static final String MODEL_MANAGE_EXPORT_TASK_NUM = "SAWP.MODEL_MANAGE_EXPORT_TASK_NUM";
	/**
	 * 样机管理-非并发定时任务执行标记
	 */
	public static final String MODEL_JOB_EXCUTE_FLAG = "SAWP.MODEL_JOB__EXCUTE_FLAG";
	/**
	 * 样机管理-非并发定时任务执行标记
	 */
	public static final int EXPIRE_TIME_ONE_DAY = 12 * 60 * 60;;
	/**
	 * 样机管理-任务接口首页
	 */
	public static final String MODEL_TASK_HOME = "model_task_Home_%s";

	/**
	 * 组织树缓存-门店
	 */
	public static final String MODEL_ORG_TREE_STORE = "model_orgTree_store_%s";

	/**
	 * 组织树缓存-分公司
	 */
	public static final String MODEL_ORG_TREE_BRANCH = "model_orgTree_branch_%s";

	/**
	 * 组织树缓存-大区
	 */
	public static final String MODEL_ORG_TREE_REGION = "model_orgTree_region_%s";

	/**
	 * 组织树缓存-任务
	 */
	public static final String MODEL_ORG_TREE_TASK = "model_orgTree_task_%s";

	/**
	 * 样机监控
	 */
	public static final String MODEL_MONITOR = "model_monitor_%s_%s";

	/**
	 * 内部优惠券黑名单
	 */
	public static final String INNER_COUPON_BLACK_LIST = "SAWP.INNER_COUPON_BLACK_LIST";

	/**
	 * 内部优惠券券详情
	 */
	public static final String INNER_COUPON_DETAIL = "SAWP.INNER_COUPON_DETAIL";

	public static final int ONE_WEEK_EXPIRE_TIME = 7 * 60 * 60 * 24;

	public static final int ONE_DAY_EXPIRE_TIME = 60 * 60 * 24;

	public static final int TWO_HOURS_EXPIRE_TIME = 60 * 60 * 2;

	public static final int HALF_HOUR_EXPIRE_TIME = 60 * 30;

	/**
	 * 内部优惠券 当月已发送次数
	 */
	public static final String INNER_COUPON_SEND_TIMES_MONTH = "SAWP.INNER_COUPON_SEND_TIMES_MONTH";

	/**
	 * 员工姓名缓存
	 */
	public static final String STAFF_NAME = "SAWP.STAFF_NAME";

	/**
	 * 样机店员名称缓存-7天
	 */
	public static final String MODEL_STAFF_NAME_BY_ID = "model_staff_name_by_%s";

	/**
	 * 根据品类区分样机督导名称缓存-7天
	 */
	public static final String MODEL_GUIDE_NAME_BY_CATE = "model_guide_name_by_%s_%s";

	/**
	 * 门店品类品牌下样机总数 缓存一天
	 */
	public static final String MODEL_CATE_BRAND_TOTAL = "MODEL_BRAND_TOTAL_%s_%s_%s";

	/**
	 * 商品簇更新时间
	 */
	public static final String MODEL_CLUSTER_IMPORT_TIME = "MODEL_CLUSTER_IMPORT_TIME";

	/**
	 * 商品簇更新时间 缓存1天
	 */
	public static final int MODEL_CLUSTER_IMPORT_TIME_EXPIRE = 60 * 60 * 24;

	/**
	 * 样机清单导出次数上限
	 */
	public static final String MODEL_EXPORT_LIMIT = "MODEL_EXPORT_TIMES";

	/**
	 * 样机清单导出次数上限 导出时间
	 */
	public static final String MODEL_EXPORT_LIMIT_TIME = "EXPORT_TIME";

	/**
	 * 样机清单导出次数上限 导出次数
	 */
	public static final String MODEL_EXPORT_LIMIT_NUM = "MODEL_EXPORT_NUM";

	/**
	 * 
	 * 新门店外拓相关的key
	 *
	 * @author 15050536 石键平
	 */
	public interface MemberExpand {
		/**
		 * 一分钟
		 */
		public static final int ONE_MINUTE_EXPIRE_TIME = 60;

		/**
		 * 五分钟
		 */
		public static final int FIVE_MINUTE_EXPIRE_TIME = 300;

		/**
		 * 半小时
		 */
		public static final int HALF_HOUR_EXPIRE_TIME = 1800;

		/**
		 * 一小时
		 */
		public static final int HOUR_EXPIRE_TIME = 3600;

		/**
		 * 半天
		 */
		public static final int HALF_DAY_EXPIRE_TIME = HOUR_EXPIRE_TIME * 12;

		/**
		 * 一天
		 */
		public static final int ONE_DAY_EXPIRE_TIME = HOUR_EXPIRE_TIME * 24;

		/**
		 * 活动列表 , 1小时过期 <br/>
		 * HASH 门店编码_状态
		 */
		String ACTIVITY_LIST = "SNSAWP:MEMBER:ACTIVITY:queryActivityList:%s_%s";

		/**
		 * 当前门店 正在进行的活动列表 -- 1小时过期
		 */
		String ACTIVITY_ACTIVE_LIST = "SNSAWP:MEMBER:ACTIVITY:queryActiveActivities:%s";

		/**
		 * 店长外拓统计数据列表 , 1小时过期<br/>
		 * key 门店编码 field 页码
		 */
		String ACTIVITY_STATIS_4DZ = "SNSAWP:MEMBER:STATIS:queryActivityStatisByStore:%s";

		/**
		 * 督导外拓统计数据列表 , 1小时过期<br/>
		 * key 门店编码_品类编码 field 页码
		 */
		String ACTIVITY_STATIS_4DD = "SNSAWP:MEMBER:STATIS:queryActivityStatisByCate:%s_%s";

		/**
		 * 店员外拓统计数据列表 , 1小时过期<br/>
		 * key 门店编码_员工工号 field 页码
		 */
		String ACTIVITY_STATIS_4DY = "SNSAWP:MEMBER:STATIS:queryActivityStatisByEmp:%s_%s";

		/**
		 * 某外拓活动统计详情 , 1小时过期<br/>
		 * key 门店编码_活动编号 field 来源_类型
		 */
		String ACTIVITY_STATIS_STORE = "SNSAWP:MEMBER:STATIS:queryCateStatisDetailByStore:%s_%s";

		/**
		 * 某外拓活动品类统计详情 , 1小时过期<br/>
		 * key 门店编码_活动编号_品类编码 field 来源_类型
		 */
		String ACTIVITY_STATIS_CATE = "SNSAWP:MEMBER:STATIS:queryEmpStatisDetailByCate:%s_%s_%s";

		/**
		 * 某外拓活动客户统计详情 , 1小时过期<br/>
		 * key 门店编码_活动编号_员工工号 field 来源_类型_页码
		 */
		String ACTIVITY_STATIS_EMP = "SNSAWP:MEMBER:STATIS:queryClientStatisDetailByEmp:%s_%s_%s";

		/**
		 * 查询某员工某活动发展的客户详情列表
		 */
		String CUSTOMER_DETAIL_LIST_BY_EMPLOYEE = "SNSAWP:MEMBER:STATIS:queryCustomerDetailByEmployeeId:%s_%s_%s_%s";

		/**
		 * 查询某员工某活动发展的客户详情列表,含销售统计数据
		 */
		String CUSTOMER_DETAIL_LIST_WITH_SALE_BY_EMPLOYEE = "SNSAWP:MEMBER:STATIS:queryCustomerDetailWithSaleByEmployeeId:%s_%s_%s_%s";

		/**
		 * 查询某门店，某品类，某活动发展的客户详情列表
		 */
		String CUSTOMER_DETAIL_LIST_BY_STORE_CATE = "SNSAWP:MEMBER:STATIS:queryCustomerDetailByStoreAndCate:%s_%s_%s_%s_%s";

		/**
		 * 查询某门店，某品类，某活动发展的客户详情列表,含销售统计数据
		 */
		String CUSTOMER_DETAIL_LIST_WITH_SALE_BY_STORE_CATE = "SNSAWP:MEMBER:STATIS:queryCustomerDetailWithSaleByStoreAndCate:%s_%s_%s_%s_%s";
	}

	/**
	 * key-value结构，value为订单明细
	 */
	public static final String EXCHANGE_ORDER_INFO = "SNSAWP:EXCHANGE:ORDER:INFO:%s";
	/**
	 * set结构，set集合为订单号
	 */
	public static final String EXCHANGE_MOBILE_ORDER = "SNSAWP:EXCHANGE:MOBILE:ORDER:%s";
	/**
	 * set结构，set集合为活动编号
	 */
	public static final String EXCHANGE_ORDER_ACTIVITY = "SNSAWP:EXCHANGE:ORDER:ACTIVITY:%s";

	/**
	 * key-value结构，value为活动名称
	 */
	public static final String EXCHANGE_ACTIVITY_INFO = "SNSAWP:EXCHANGE:ACTIVITY:INFO:%s";

	/**
	 * key-value结构，value为所有城市
	 */
	public static final String EXCHANGE_ALL_CITY = "SNSAWP:EXCHANGE:ALL:CITY";

	/**
	 * 所有的标签库集合
	 */
	public static final String ALL_LABELS = "SNSAWP:ALL:LABEL";
}
